package top.yueyazhui.vhr.mapper;

import org.apache.ibatis.annotations.Param;
import top.yueyazhui.vhr.model.Employee;

import java.util.Date;
import java.util.List;

public interface EmployeeMapper {

    int deleteByPrimaryKey(Integer id);

    int insert(Employee record);

    int insertSelective(Employee record);

    Employee selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(Employee record);

    int updateByPrimaryKey(Employee record);

    List<Employee> getAllEmployeeByPage(@Param("page") Integer page, @Param("size") Integer size, @Param("employee") Employee employee, @Param("beginDateScope") Date[] beginDateScope);

    Long getTotal(@Param("employee") Employee employee, @Param("beginDateScope") Date[] beginDateScope);

    Integer getMaxWorkId();

    Integer inserts(@Param("list") List<Employee> list);

    Employee getEmployeeById(Integer id);

    List<Employee> getAllEmployee();

    List<Employee> getAllEmployeeByPageWithSalary(@Param("page") Integer page, @Param("size") Integer size);

    Long getTotalWithSalary();

    Integer updateEmployeeSalaryById(@Param("employeeId") Integer employeeId, @Param("salaryId") Integer salaryId);
}